function [r,rpp] = TryWiden( pnums, ssf, npts, niters, scaleFactor )
    rpp = [];
    sfeff = scaleFactor;
    wasgood = false;
    for ii = 1:niters
        for i = 1:length(pnums)
            oldssf = ssf(i);
            ssf(i) = ssf(i) * sfeff;
            fprintf('\niter = %2i,  param num = %2i,  oldssf = %12.10f,  newssf = %12.10f\n\n',ii,i,oldssf, ssf(i));            
            pp = CalcPpedSimple(pnums, ssf);        
            rg = CheckPpedGoodness_p(pnums, pp, npts);
            if(rg < 0.95) 
                ssf(i) = oldssf;;
            else
                rpp = pp;
                fprintf('New good ssf found!!!\n');
                disp(ssf)
                wasgood = true;
            end
        end
        
        if wasgood == false
            sfeff = (1 + sfeff) / 2;
        end
        wasgood = false;
    end
    r = ssf;
end

